﻿using System.Collections.Generic;
using System.Data;
using System.Data.SqlClient;
using Microsoft.ApplicationBlocks.Data;
using wsRK.BaseObject;
using wsRK.BusinessObjectHelper;

namespace nkstdgia.common.Document
{
    public class DocumentDataService : BaseDataService
    {
        #region Constructor

        public DocumentDataService()
        {
        }

        #endregion Constructor

        public List<DocumentInfo> searchDuong(int QUANID, int PHUONGID)
        {
            return CBO.FillCollection<DocumentInfo>((IDataReader)SqlHelper.ExecuteReader(
                this.strConnectring,
                CommandType.StoredProcedure,
                "sproc_DUONG_KHAO_SAT_searchDuong",
                new SqlParameter("@QUANID", QUANID),
                 new SqlParameter("@PHUONGID", PHUONGID)
                 ));
        }

        public List<DocumentInfo> searchDoanDuong(int QUANID, int PHUONGID)
        {
            return CBO.FillCollection<DocumentInfo>((IDataReader)SqlHelper.ExecuteReader(
                this.strConnectring,
                CommandType.StoredProcedure,
                "sproc_DUONG_KHAO_SAT_searchDoanDuong",
                new SqlParameter("@QUANID", QUANID),
                 new SqlParameter("@PHUONGID", PHUONGID)
                 ));
        }
    }
}
